package com.zimmor;


import org.springframework.beans.factory.annotation.Value;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.cloud.context.config.annotation.RefreshScope;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @Author:zimmor
 * @Date: 2021/5/5 21:13
 * @Description
 * @version: 1.0.0
 */
@SpringBootApplication
@RefreshScope
@RestController
public class Service1Application {
    public static void main(String[] args) {
        SpringApplication.run(Service1Application.class);
    }

    @Value("${common.name}")
    private String name;
    @Value("${server.port}")
    private String port;

    @GetMapping("/service1/config")
    public String getConfig() {
        return port;
    }


}
